package com.szpx.entity.HZJ;

import javax.persistence.*;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 课程实体类
 */
@Entity
@Table(name = "course_package") // 已修改为映射到 "course" 表
public class Course { // 类名已修改为 Course

    /**
     * 主键ID
     */
    @Id
    private Long id;

    /**
     * 班型名称 (如: 基础班)
     */
    @Column(name = "name", nullable = false)
    private String name;

    /**
     * 班型描述
     */
    @Column(name = "description")
    private String description;

    /**
     * 价格
     */
    @Column(name = "price", nullable = false)
    private BigDecimal price;

    /**
     * 包含的服务内容
     */
    @Column(name = "included_services")
    private String includedServices;

    /**
     * 状态 (例如: 启用, 停用)
     */
    @Column(name = "status", nullable = false)
    private String status;

    /**
     * 创建时间
     */
    @Temporal(TemporalType.TIMESTAMP)
    @Column(name = "created_at", updatable = false)
    private Date createdAt;

    /**
     * 更新时间
     */
    @Temporal(TemporalType.TIMESTAMP)
    @Column(name = "updated_at")
    private Date updatedAt;


    // --- 构造函数 ---
    public Course() {
    }

    // --- Getters 和 Setters ---

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public String getIncludedServices() {
        return includedServices;
    }

    public void setIncludedServices(String includedServices) {
        this.includedServices = includedServices;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public Date getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(Date createdAt) {
        this.createdAt = createdAt;
    }

    public Date getUpdatedAt() {
        return updatedAt;
    }

    public void setUpdatedAt(Date updatedAt) {
        this.updatedAt = updatedAt;
    }
}
